package com.cy2;

import java.io.File;
import java.io.IOException;

public class DiGuiDemo {
    public static void main(String[] args) throws IOException {
        File src = new File("c:\\");
        getAllFiles(src);

    }

    public static void getAllFiles(File src) {
        File[] files = src.listFiles();
        if (files != null) {
            for (File file : files) {
                if (file.isDirectory()) {
                    getAllFiles(file);
                } else {
                    System.out.println(file.getAbsoluteFile());
                }
            }
        }
    }
}
